<?xml version="1.0" encoding="ascii"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
          "DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <title>pygccxml.parser.directory_cache.directory_cache_t</title>
  <link rel="stylesheet" href="epydoc.css" type="text/css" />
  <script type="text/javascript" src="epydoc.js"></script>
</head>

<body bgcolor="white" text="black" link="blue" vlink="#204080"
      alink="#204080">
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">
  <!-- Home link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="pygccxml-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://www.language-binding.net">pygccxml</a></th>
          </tr></table></th>
  </tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0">
  <tr valign="top">
    <td width="100%">
      <span class="breadcrumbs">
        <a href="pygccxml-module.html">Package&nbsp;pygccxml</a> ::
        <a href="pygccxml.parser-module.html">Package&nbsp;parser</a> ::
        <a href="pygccxml.parser.directory_cache-module.html">Module&nbsp;directory_cache</a> ::
        Class&nbsp;directory_cache_t
      </span>
    </td>
    <td>
      <table cellpadding="0" cellspacing="0">
        <!-- hide/show private -->
      </table>
    </td>
  </tr>
</table>
<!-- ==================== TYPE DESCRIPTION ==================== -->
<h1 class="epydoc">type directory_cache_t</h1><p class="nomargin-top"><span class="codelink"><a href="pygccxml.parser.directory_cache-pysrc.html#directory_cache_t">source&nbsp;code</a></span></p>
<pre class="base-tree">
                     object --+    
                              |    
<a href="pygccxml.parser.declarations_cache.cache_base_t-class.html">declarations_cache.cache_base_t</a> --+
                                  |
                                 <strong class="uidshort">directory_cache_t</strong>
</pre>

<hr />
<p>Cache class that stores its data as multiple files inside a 
  directory.</p>
  <p>The cache stores one index file called &quot;index.dat&quot; which is 
  always read by the cache when the cache object is created. Each header 
  file will have its corresponding *.cache file that stores the 
  declarations found in the header file. The index file is used to 
  determine whether a *.cache file is still valid or not (by checking if 
  one of the dependent files (i.e. the header file itself and all included 
  files) have been modified since the last run).</p>

<!-- ==================== INSTANCE METHODS ==================== -->
<a name="section-InstanceMethods"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td align="left" colspan="2" class="table-header">
    <span class="table-header">Instance Methods</span></td>
</tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pygccxml.parser.directory_cache.directory_cache_t-class.html#__init__" class="summary-sig-name">__init__</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">dir</span>=<span class="summary-sig-default"><code class="variable-quote">'</code><code class="variable-string">cache</code><code class="variable-quote">'</code></span>,
        <span class="summary-sig-arg">compression</span>=<span class="summary-sig-default">False</span>,
        <span class="summary-sig-arg">md5_sigs</span>=<span class="summary-sig-default">True</span>)</span><br />
      Constructor.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygccxml.parser.directory_cache-pysrc.html#directory_cache_t.__init__">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pygccxml.parser.directory_cache.directory_cache_t-class.html#flush" class="summary-sig-name">flush</a>(<span class="summary-sig-arg">self</span>)</span><br />
      Save the index table to disk.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygccxml.parser.directory_cache-pysrc.html#directory_cache_t.flush">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pygccxml.parser.directory_cache.directory_cache_t-class.html#update" class="summary-sig-name">update</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">source_file</span>,
        <span class="summary-sig-arg">configuration</span>,
        <span class="summary-sig-arg">declarations</span>,
        <span class="summary-sig-arg">included_files</span>)</span><br />
      Replace a cache entry by a new value.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygccxml.parser.directory_cache-pysrc.html#directory_cache_t.update">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pygccxml.parser.directory_cache.directory_cache_t-class.html#cached_value" class="summary-sig-name">cached_value</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">source_file</span>,
        <span class="summary-sig-arg">configuration</span>)</span><br />
      Return the cached declarations or None.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygccxml.parser.directory_cache-pysrc.html#directory_cache_t.cached_value">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
</table>
<!-- ==================== CLASS VARIABLES ==================== -->
<a name="section-ClassVariables"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td align="left" colspan="2" class="table-header">
    <span class="table-header">Class Variables</span></td>
</tr>
  <tr>
    <td colspan="2" class="summary">
    <p class="indent-wrapped-lines"><b>Inherited from <code><a href="pygccxml.parser.declarations_cache.cache_base_t-class.html">declarations_cache.cache_base_t</a></code></b>:
      <code><a href="pygccxml.parser.declarations_cache.cache_base_t-class.html#logger">logger</a></code>
      </p>
    </td>
  </tr>
</table>
<!-- ==================== METHOD DETAILS ==================== -->
<a name="section-MethodDetails"></a>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td align="left" colspan="2" class="table-header">
    <span class="table-header">Method Details</span></td>
</tr>
</table>
<a name="__init__"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">__init__</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">dir</span>=<span class="sig-default"><code class="variable-quote">'</code><code class="variable-string">cache</code><code class="variable-quote">'</code></span>,
        <span class="sig-arg">compression</span>=<span class="sig-default">False</span>,
        <span class="sig-arg">md5_sigs</span>=<span class="sig-default">True</span>)</span>
    <br /><em class="fname">(Constructor)</em>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pygccxml.parser.directory_cache-pysrc.html#directory_cache_t.__init__">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Constructor.</p>
  <p>dir is the cache directory (it is created if it does not exist). If 
  compression is set to True the cache files will be compressed using gzip.
  md5_sigs determines whether file modifications is checked by computing a 
  md5 digest or by checking the modification date.</p>
  <dl class="fields">
    <dt>Overrides:
        <a href="pygccxml.parser.declarations_cache.cache_base_t-class.html#__init__">declarations_cache.cache_base_t.__init__</a>
    </dt>
  </dl>
</td></tr></table>
</div>
<a name="flush"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">flush</span>(<span class="sig-arg">self</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pygccxml.parser.directory_cache-pysrc.html#directory_cache_t.flush">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Save the index table to disk.</p>
  <dl class="fields">
    <dt>Overrides:
        <a href="pygccxml.parser.declarations_cache.cache_base_t-class.html#flush">declarations_cache.cache_base_t.flush</a>
    </dt>
  </dl>
</td></tr></table>
</div>
<a name="update"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">update</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">source_file</span>,
        <span class="sig-arg">configuration</span>,
        <span class="sig-arg">declarations</span>,
        <span class="sig-arg">included_files</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pygccxml.parser.directory_cache-pysrc.html#directory_cache_t.update">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Replace a cache entry by a new value.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>source_file</code></strong> (str) - Header file name.</li>
        <li><strong class="pname"><code>configuration</code></strong> (<a 
          href="pygccxml.parser.config.gccxml_configuration_t-class.html" 
          class="link">config_t</a>) - Configuration  object.</li>
        <li><strong class="pname"><code>declarations</code></strong> (picklable object) - Declarations contained in the header file.</li>
        <li><strong class="pname"><code>included_files</code></strong> (list of str) - Dependent files</li>
    </ul></dd>
    <dt>Overrides:
        <a href="pygccxml.parser.declarations_cache.cache_base_t-class.html#update">declarations_cache.cache_base_t.update</a>
    </dt>
  </dl>
</td></tr></table>
</div>
<a name="cached_value"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">cached_value</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">source_file</span>,
        <span class="sig-arg">configuration</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pygccxml.parser.directory_cache-pysrc.html#directory_cache_t.cached_value">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Return the cached declarations or None.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>source_file</code></strong> (str) - Header file name</li>
        <li><strong class="pname"><code>configuration</code></strong> (<a 
          href="pygccxml.parser.config.gccxml_configuration_t-class.html" 
          class="link">config_t</a>) - Configuration object</li>
    </ul></dd>
    <dt>Returns:</dt>
        <dd>Cached declarations or None</dd>
    <dt>Overrides:
        <a href="pygccxml.parser.declarations_cache.cache_base_t-class.html#cached_value">declarations_cache.cache_base_t.cached_value</a>
    </dt>
  </dl>
</td></tr></table>
</div>
<br />
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">
  <!-- Home link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="pygccxml-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://www.language-binding.net">pygccxml</a></th>
          </tr></table></th>
  </tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" width="100%%">
  <tr>
    <td align="left" class="footer">
    Generated by Epydoc 3.0.1
    on Mon Oct 20 09:00:21 2008
    </td>
    <td align="right" class="footer">
      <a target="mainFrame" href="http://epydoc.sourceforge.net"
        >http://epydoc.sourceforge.net</a>
    </td>
  </tr>
</table>

<script type="text/javascript">
  <!--
  // Private objects are initially displayed (because if
  // javascript is turned off then we want them to be
  // visible); but by default, we want to hide them.  So hide
  // them unless we have a cookie that says to show them.
  checkCookie();
  // -->
</script>
</body>
</html>
